package com.woniuxy.commons.rabbit;

/**
 * @ClassName PurchaseOrderRabbitConfiguration
 * @Description 采购单rabbitmq配置类
 * @Author xianhao
 * @Date 2022/4/28 13:17
 * @Version 1.0.0
 */
// @Configuration
// public class PurchaseOrderRabbitConfiguration {
//
//     @Bean
//     public Queue okQueue() {    //队列名字
//         return new Queue(RabbitMqConst.QUEUE_PURCHASE_OK);
//     }
//
//     @Bean
//     public Queue cancelQueue(){ //队列名字
//         return new Queue(RabbitMqConst.QUEUE_PURCHASE_CANCEL);
//     }
//
//     @Bean       //交换机
//     public DirectExchange directExchange(){
//         return new DirectExchange(RabbitMqConst.EXCHANGE_DIRECT_PRODUCT);
//     }
//
//     @Bean
//     public Binding bindingNewsQueueAndExchange(DirectExchange directExchange, Queue okQueue){
//         return BindingBuilder.bind(okQueue).to(directExchange).with(RabbitMqConst.PURCHASE_ORDER_ROUTING_OK_KEY);
//     }
//
//     @Bean
//     public Binding bindingWeatherQueueAndExchange(DirectExchange directExchange,Queue cancelQueue){
//         return BindingBuilder.bind(cancelQueue).to(directExchange).with(RabbitMqConst.PURCHASE_ORDER_ROUTING_CANCEL_KEY);
//     }
// }
